package com.revelvy.pojo;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.hibernate.validator.constraints.Length;
import org.springframework.validation.annotation.Validated;

import javax.validation.constraints.NotBlank;

/**
 * Author: Revelvy
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
@Validated
public class Roles {
    private Integer roleId;
    @NotBlank(message = "角色名不允许为空")
    @Length(min = 3, max = 10, message = "角色名长度必须在{min}~{max}个字符之间")
    private String roleName;
    private String rightsIds;
    private String roleDesc;
}